using UnityEngine;

public class NewBootUp_ProxyProgram : MonoBehaviour
{
	[SerializeField]
	private float DefaultMoveSpeed;

	[SerializeField]
	private float DefaultSlowMoveSpeed;

	private float CurrentSoulMoveSpeed;

	public Rigidbody2D SoulRigidbody;

	private Vector2 _StoredMoveDIR;

	private bool HoldingSlowKey;

	private void Update()
	{
		ProcessRedInputs();
	}

	private void ProcessRedInputs()
	{
		float horizontalInput = PlayerInput.GetHorizontalInput();
		float verticalInput = PlayerInput.GetVerticalInput();
		_StoredMoveDIR = new Vector2(horizontalInput, verticalInput);
		HoldingSlowKey = Input.GetKey(PlayerInput.Instance.Key_Sprint);
		if (HoldingSlowKey)
		{
			CurrentSoulMoveSpeed = DefaultSlowMoveSpeed;
		}
		else
		{
			CurrentSoulMoveSpeed = DefaultMoveSpeed;
		}
		SoulRigidbody.velocity = new Vector2(_StoredMoveDIR.normalized.x * CurrentSoulMoveSpeed * Time.fixedDeltaTime, _StoredMoveDIR.normalized.y * CurrentSoulMoveSpeed * Time.fixedDeltaTime);
	}
}
